<!DOCTYPE html>
<html>
	<head>
		<meta charset="utf-8">
		<title></title>
		<script type="text/javascript">
			// 定义、赋值变量score
			var score = 50;
			// 变量除以10,int取整
/*			wsitch(parseInt(score/10)){
				case 10:
				case 9:
				case 8:
				case 7:
				case 6:
				   console.log("合格");
				   break;
				default:
				   console.log("不合格");
				   break;     */
				   
		//********* 优化***********
		switch(true){
			case score >= 60:
			console.log("合格");
			break;
			default:
			console.log("不合格");
			break;
			}
		</script>
	</head>
	<body>
	</body>
</html>
